.panel.panel-default(ng-class="results2class(buildsummary.build)", style="margin-bottom:0px")
    .panel-heading.no-select
        .flex-row
            .flex-grow-1
                .btn.btn-xs.btn-default(ng-click="buildsummary.toggleFullDisplay()", title="Expand all step logs")
                    i.fa.fa-chevron-circle-right.rotate(ng-class="{'fa-rotate-90':buildsummary.fulldisplay}")
                .btn.btn-xs.btn-default(ng-click="buildsummary.toggleDetails()", title="Show steps according to their importance")
                    i.fa.fa-expand
                    | {{buildsummary.levelOfDetails()}}
                | #{' '}
                span(ng-if="buildsummary.prefix") {{buildsummary.prefix}}#{' '}
                a(ui-sref="build({builder:buildsummary.build.builderid, build:buildsummary.build.number})")
                  | {{buildsummary.builder.name}}/{{buildsummary.build.number}}#{' '}
                span(ng-if="buildsummary.reason") | {{buildsummary.reason}}
            .flex-grow-1.text-right
                span(ng-show="buildsummary.build.complete")
                    | {{(buildsummary.build.complete_at - buildsummary.build.started_at)| durationformat:'LLL' }}
                span(ng-show="!buildsummary.build.complete")
                    | {{(buildsummary.now - buildsummary.build.started_at)| durationformat:'LLL' }}
                span
                  | #{' '}{{buildsummary.build.state_string}}#{' '}
                .label(ng-class="results2class(buildsummary.build)")
                  | {{results2text(buildsummary.build)}}
                span(ng-if="buildsummary.parentbuild")
                    | #{' '}
                    a.label(ng-class="results2class(buildsummary.parentbuild)",
                    ui-sref="build({builder:buildsummary.parentbuilder.builderid, build:buildsummary.parentbuild.number})")
                          | {{buildsummary.parentrelationship}}:
                          | {{buildsummary.parentbuilder.name}}/{{buildsummary.parentbuild.number}}
    ul.list-group.no-select
      li.list-group-item(ng-if="buildsummary.isStepDisplayed(step)"
                         ng-repeat="step in buildsummary.steps | orderBy: ['stepid']")
        div(ng-click="step.fulldisplay=!step.fulldisplay")
            span.pull-right(ng-if="step.started_at")
              span(ng-show="step.complete")
                  | {{ step.duration| durationformat:'LLL' }}
              span(ng-show="!step.complete")
                  | {{ buildsummary.now - step.started_at| durationformat:'LLL' }}
              | #{' '}{{step.state_string}}
            span.badge-status(ng-class="results2class(step, 'pulse')")
              | {{step.number}}
            | #{' '}
            i.fa.fa-chevron-circle-right.rotate(ng-class="{'fa-rotate-90':step.fulldisplay}", ng-if="step.logs.length")
            | #{' '} {{step.name}}
        ul
          li(ng-if='!(buildsummary.isBuildRequestURL(url.url) || buildsummary.isBuildURL(url.url))', ng-repeat="url in step.urls")
            a(target="_blank", ng-href="{{url.url}}") {{url.name}}
        ul.list-unstyled
          li(ng-if='buildsummary.isBuildRequestURL(url.url)', ng-repeat="url in step.urls")
            buildrequestsummary(style="margin-left:30px;margin-top:8px",buildrequestid='buildsummary.getBuildRequestIDFromURL(url.url)')
        div.anim-stepdetails(ng-if="step.fulldisplay")
          logpreview(ng-repeat="log in step.logs", log="log",
                     fulldisplay="step.logs.length == 1",
                     builderid="buildsummary.build.builderid", buildnumber="buildsummary.build.number",
                     step="step")
